package com.cherry.amqp;

import org.springframework.amqp.rabbit.annotation.EnableRabbit;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
 * 自动配置
 *  1、RabbitAutoConfiguration
 *  2、有自动配置了连接工厂ConnectionFactory；
 *  3、RabbitProperties 封装了RabbitMQ的配置
 *      - RabbitTemplate ：给RabbitMQ发送和接受消息；
 *      - AmqpAdmin：RabbitMQ系统管理功能组件;创建和删除 Queue，Exchange，Binding
 *  4、@EnableRabbit + @RabbitListener 监听消息队列的内容
 *
 *  测试案例:SpringbootAmqpApplicationTests
 */
@EnableRabbit //开启基于注解的RabbitMQ模式
@SpringBootApplication
public class SpringbootAmqpApplication {

    public static void main(String[] args) {
        SpringApplication.run(SpringbootAmqpApplication.class, args);
    }

}
